Journals
  Publication Years
  Keywords
Search within results Open Search
Please wait a minute...
For Selected: Toggle Thumbnails
Text adversarial example generation method based on BERT model
Yuhang LI, Yuli YANG, Yao MA, Dan YU, Yongle CHEN
Journal of Computer Applications    2023, 43 (10): 3093-3098.   DOI: 10.11772/j.issn.1001-9081.2022091468
Abstract342)   HTML21)    PDF (971KB)(231)       Save

Aiming at the problem that the existing adversarial example generation methods require a lot of queries to the target model, which leads to poor attack effects, a Text Adversarial Examples Generation Method based on BERT (Bidirectional Encoder Representations from Transformers) model (TAEGM) was proposed. Firstly, the attention mechanism was adopted to locate the keywords that significantly influence the classification results without query of the target model. Secondly, word-level perturbation of keywords was performed by BERT model to generate candidate adversarial examples. Finally, the candidate examples were clustered, and the adversarial examples were selected from the clusters that have more influence on the classification results. Experimental results on Yelp Reviews, AG News, and IMDB Review datasets show that compared to the suboptimal adversarial example generation method CLARE (ContextuaLized AdversaRial Example generation model) on Success Rate (SR), TAEGM can reduce the Query Counts (QC) to the target model by 62.3% and time consumption by 68.6% averagely while ensuring the SR of adversarial attacks. Based on the above, further experimental results verify that the adversarial examples generated by TAEGM not only have good transferability, but also improve the robustness of the model through adversarial training.

Table and Figures | Reference | Related Articles | Metrics